class Base {
    public int a;
    public int b;
    public int c = 199;
    public void methodBase() {
        System.out.println("Base");
    }
}
class Derived extends Base {
    public int c = 9;
    public void methodDerived() {
        System.out.println("Derived");
    }
        public void methodBase() {
            System.out.println("Derived");
    }
    public void func() {
        methodBase();//子类
        super.methodBase();//父类
        methodDerived();
    }

    public void func1() {
        //子类有 那么就拿子类的，子类没有，就拿父类的
        System.out.println(a);
        System.out.println(b);
        System.out.println(c);//如果父类和子类有同名的成员变量，优先访问子类自己的
        System.out.println(super.c);

    }
}

public class Test2 {
    public static void main(String[] args) {
        final int[] array = {1,2,3};



        //array = new int[10];
        array[0] = 19;
    }
    public static void main1(String[] args) {
        Derived derived = new Derived();
        derived.func();
    }
}
